#ifndef RP2ZBUFFERSTATE_H
#define RP2ZBUFFERSTATE_H

#include "Rp2GlobalState.h"

namespace Rp2
{
class ZBufferState : public GlobalState
{
	RP2_DECLARE_INITIALIZE;
	RP2_DECLARE_TERMINATE;

public:
	ZBufferState();
	virtual ~ZBufferState();

	virtual StateType GetStateType() const {return ZBUFFER; }

    enum CompareMode
    {
        CF_NEVER,
        CF_LESS,
        CF_EQUAL,
        CF_LEQUAL,
        CF_GREATER,
        CF_NOTEQUAL,
        CF_GEQUAL,
        CF_ALWAYS,
        CF_QUANTITY
    };

	bool Enabled;			//default : true
	bool Writable;			//default : true
	CompareMode Compare;	//default : CF_LEQUAL;

};

RP2_REGISTER_INITIALIZE(ZBufferState);
RP2_REGISTER_TERMINATE(ZBufferState);
typedef Pointer<ZBufferState> ZBufferStatePtr;

}

#endif